Console create instance reads the maxLogLevel pref on every log
Categories
(DevTools :: Console, task, P3)
Tracking
(Performance Impact:none)
Performance Impact | none |
People
(Reporter: gregtatum, Assigned: gregtatum)
References
(Blocks 1 open bug)
Details
(Keywords: perf)
Attachments
(2 obsolete files)
Translations is a heavy user of console.createInstance
to allow for debug-only logging. However, this keeps on tripping up the browser/base/content/test/performance/browser_preferences_usage.js
test. I investigated and it appears that the log level mechanism reads the preference on every single log call, rather than retaining the preference value, and updating it via an observer.
This change fixes Bug 1835693.
Assignee | ||
Comment 1•2 years ago
|
||
This change is covered by dom/console/tests/test_jsm.xhtml
Assignee | ||
Comment 2•2 years ago
|
||
This change is covered by dom/console/tests/test_jsm.xhtml
Updated•2 years ago
|
Comment 3•2 years ago
|
||
I'm guessing this isn't a huge perf impact at the moment, but I'm wondering what might happen if we transition all front-end logging to it.
Assignee | ||
Comment 4•2 years ago
|
||
It shows up a bit, mostly in profiler markers though. This hasn't been a huge priority to go back and handle the review comments, although I would like to. The biggest blocker is tripping browser/base/content/test/performance/browser_preferences_usage.js
.
Comment 5•2 years ago
|
||
(In reply to Mark Banner (:standard8) from comment #3)
I'm guessing this isn't a huge perf impact at the moment, but I'm wondering what might happen if we transition all front-end logging to it.
Hi Mark, this type of ticket falls outside of the scope of a performance impact triage calculator. Our suggestion would be to reach out to the performance team using #perf-help in Slack to get some more specific assistance in reviewing the logging story. We'll best be able to assess perf impacts from there. Thanks
Comment 6•1 year ago
|
||
I'd forgotten about this bug and I've just fixed it in bug 1876589.
Updated•1 year ago
|
Description
•